<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<meta charset="UTF-8">
<title>部门查询</title>
<link rel="stylesheet" href="http://yui.yahooapis.com/pure/0.6.0/pure-min.css"/>
<style>
article { padding: 10px; }
.myaddbtn { margin: 10px 0; margin-bottom: 20px; }
footer { position: dixed; bottom: 0; text-align: center; width: 100%; }
</style>

</head>
<body>
<article>
	<div class="pure-g">
	    <div class="pure-u-1-1">
			<table class="pure-table pure-table-striped">
		    <thead>
		    <tr>
		        <th>序号</th>
		        <th>部门名称</th>
		        <th>描述</th>
		        <th>操作</th>
		    </tr>
		    </thead>

		    <tbody>
		    <s:iterator value="list" var="d"  status="status">
					<tr>
						<td><s:property value="did" /></td>
						<td><s:property value="dnameString" /></td>
						<td><s:property value="#d.descc" /></td>
						<td><a href="department/Department_delete.action?did=<s:property value="did" />" onclick="javascript: return confirm('真的要删除吗？');">1.删除</a>--<a href="department/Department_edit.action?did=<s:property value="did" />">2.编辑</a></td>
					</tr>
				</s:iterator>
		    </tbody>
		</table>
		</div>
		<div class="pure-u-1-1">
			<a class="pure-button myaddbtn" href="department/Department_add.action">添加一个部门</a>
		</div>
	</div>
</article>

<footer>
	当前第<s:property value="currPage"/>页/共<s:property value="totalPage"/>页&nbsp;&nbsp;
	一共<s:property value="totalCount"/>条数据&nbsp;&nbsp;
	每页显示<s:property value="pageSize"/>条数据&nbsp;&nbsp;
	<s:if test="currPage!=1">
		<a href="department/Department_queryBP.action?currpage=1">首页</a>&nbsp;&nbsp;
		<a href="department/Department_queryBP.action?currpage=<s:property value="currPage-1"/>">上一页</a>&nbsp;&nbsp;
	</s:if>
	<s:if test="currPage!=totalPage">
		<a href="department/Department_queryBP.action?currpage=<s:property value="currPage+1"/>">下一页</a>&nbsp;&nbsp;
		<a href="department/Department_queryBP.action?currpage=<s:property value="totalPage"/>">尾页</a>&nbsp;&nbsp;
	</s:if>
</footer>
</body>
</html>